<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
 <head>
  <meta http-equiv="content-type" content="text/html; charset=UTF-8">
  <title>从用户缓存中删除某个变量</title>
 </head>
 <body class="docs"><div id="layout">
  <div id="layout-content"><div id="function.apc-delete" class="refentry">
 <div class="refnamediv">
  <h1 class="refname">apc_delete</h1>
  <p class="verinfo">(PECL apc &gt;= 3.0.0)</p><p class="refpurpose"><span class="refname">apc_delete</span> &mdash; <span class="dc-title">
   从用户缓存中删除某个变量
  </span></p>

 </div>
 <div class="refsect1 description" id="refsect1-function.apc-delete-description">
  <h3 class="title">说明</h3>
  <div class="methodsynopsis dc-description">
   <span class="methodname"><strong>apc_delete</strong></span>
    ( <span class="methodparam"><span class="type">string</span> <code class="parameter">$key</code></span>
   ) : <span class="type"><a href="language.pseudo-types.html#language.types.mixed" class="type mixed">mixed</a></span></div>

  <p class="para rdfs-comment">
   从数据存储里删除某个变量。
  </p>
 </div>

 <div class="refsect1 parameters" id="refsect1-function.apc-delete-parameters">
  <h3 class="title">参数</h3>
  <p class="para">
   <dl>

    
     <dt>
<code class="parameter">key</code></dt>

     <dd>

      <p class="para">
       <code class="parameter">key</code> 即是你用
       <span class="function"><a href="apc_store.html" class="function">apc_store()</a></span> 存储数据时所设定的标记名称。
      </p>
     </dd>

    
   </dl>

  </p>
 </div>

 <div class="refsect1 returnvalues" id="refsect1-function.apc-delete-returnvalues">
  <h3 class="title">返回值</h3>
  <p class="para">
   成功时返回 <strong><code>TRUE</code></strong>， 或者在失败时返回 <strong><code>FALSE</code></strong>。
  </p>
 </div>

 
 <div class="refsect1 examples" id="refsect1-function.apc-delete-examples">
  <h3 class="title">范例</h3>
  <p class="para">
   <div class="example" id="example-405">
    <p><strong>Example #1 A <span class="function"><strong>apc_delete()</strong></span> 范例</strong></p>
    <div class="example-contents">
<div class="phpcode"><pre><span style="color: #000000">
<span style="color: #0000BB">&lt;?php<br />$bar&nbsp;</span><span style="color: #007700">=&nbsp;</span><span style="color: #DD0000">'BAR'</span><span style="color: #007700">;<br /></span><span style="color: #0000BB">apc_store</span><span style="color: #007700">(</span><span style="color: #DD0000">'foo'</span><span style="color: #007700">,&nbsp;</span><span style="color: #0000BB">$bar</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">apc_delete</span><span style="color: #007700">(</span><span style="color: #DD0000">'foo'</span><span style="color: #007700">);<br /></span><span style="color: #FF8000">//&nbsp;this&nbsp;is&nbsp;obviously&nbsp;useless&nbsp;in&nbsp;this&nbsp;form<br /></span><span style="color: #0000BB">?&gt;</span>
</span>
</pre></div>
    </div>

   </div>
  </p>
 </div>

 
 <div class="refsect1 seealso" id="refsect1-function.apc-delete-seealso">
  <h3 class="title">参见</h3>
  <p class="para">
   <ul class="simplelist">
    <li class="member"><span class="function"><a href="apc_store.html" class="function" rel="rdfs-seeAlso">apc_store()</a> - Cache a variable in the data store</span></li>
    <li class="member"><span class="function"><a href="apc_fetch.html" class="function" rel="rdfs-seeAlso">apc_fetch()</a> - 从缓存中取出存储的变量</span></li>
   </ul>
  </p>
 </div>

 
</div></div></div></body></html>